<!DOCTYPE html>
<html>
<head>
	<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
	<meta name="generator" content="ApiGen; http://apigen.org" />

	<title>Class Nette\Collections\Set</title>

	<link rel="stylesheet" href="resources/style.css?v=2011071314" type="text/css" media="all" />
	<link rel="shortcut icon" href="/favicon.ico" type="image/x-icon" />
	<link rel="search" href="opensearch.xml" type="application/opensearchdescription+xml" title="Nette Framework API documentation" />
	<script type="text/javascript" src="resources/combined.js"></script>
	<script type="text/javascript" src="allclasses.js"></script>
</head>

<body>
<div id="left">
	<a href="allclasses.html">All Classes</a>

	<h3>Namespaces</h3>
	<ul>
		<li><a href="namespace-none.html">none</a>
		</li>
		<li><a href="namespace-Nette.html">Nette</a>
		</li>
		<li><a href="namespace-Nette.Application.html">Nette\Application</a>
		</li>
		<li><a href="namespace-Nette.Caching.html">Nette\Caching</a>
		</li>
		<li class="active"><a href="namespace-Nette.Collections.html">Nette\Collections</a>
		</li>
		<li><a href="namespace-Nette.Config.html">Nette\Config</a>
		</li>
		<li><a href="namespace-Nette.Forms.html">Nette\Forms</a>
		</li>
		<li><a href="namespace-Nette.IO.html">Nette\IO</a>
		</li>
		<li><a href="namespace-Nette.Loaders.html">Nette\Loaders</a>
		</li>
		<li><a href="namespace-Nette.Mail.html">Nette\Mail</a>
		</li>
		<li><a href="namespace-Nette.Reflection.html">Nette\Reflection</a>
		</li>
		<li><a href="namespace-Nette.Security.html">Nette\Security</a>
		</li>
		<li><a href="namespace-Nette.Templates.html">Nette\Templates</a>
		</li>
		<li><a href="namespace-Nette.Web.html">Nette\Web</a>
		</li>
		<li><a href="namespace-PHP.html">PHP</a>
		</li>
	</ul>

	<hr />

	<h3>Classes</h3>

	<ul>
		<li><a href="Nette.Collections.ArrayList.html">ArrayList</a></li>
		<li><a href="Nette.Collections.Collection.html">Collection</a></li>
		<li><a href="Nette.Collections.Hashtable.html">Hashtable</a></li>
		<li class="active"><a href="Nette.Collections.Set.html">Set</a></li>
	</ul>

	<h3>Interfaces</h3>

	<ul>
		<li><a href="Nette.Collections.ICollection.html">ICollection</a></li>
		<li><a href="Nette.Collections.IList.html">IList</a></li>
		<li><a href="Nette.Collections.IMap.html">IMap</a></li>
		<li><a href="Nette.Collections.ISet.html">ISet</a></li>
	</ul>

	<h3>Exceptions</h3>

	<ul>
		<li><a href="Nette.Collections.KeyNotFoundException.html">KeyNotFoundException</a></li>
	</ul>
</div>

<div id="right">
	<form action="http://www.google.com/cse" id="search" onsubmit="if(this.q.value.indexOf('more:')==-1)this.q.value+=' more:api'">
		<input type="hidden" name="cx" value="011549293477758430224:vxofa9ufnhc" /><input type="hidden" name="ie" value="UTF-8" /><input type="text" name="q" class="text" /><input type="submit" value="Search" />
	</form>

<div id="navigation">
	<ul>
		<li><a href="overview.html" title="Summary of all namespaces">Overview</a></li>
		<li><a href="namespace-Nette.Collections.html" title="Summary of Nette\Collections">Namespace</a></li>
		<li class="active">Class</li>
		<li><a href="elements.html">Elements</a></li>
	</ul>
</div>

<div id="content">
	<div id="classSummary">
		<p>namespace <a href="namespace-Nette.Collections.html">Nette\Collections</a></p>

		<h1>Class Set</h1>

		<div class="classDescription">
		
<p>Provides the base class for a collection that contains no duplicate
elements.</p>

		</div>

		<dl class="tree">
			<dd style="padding-left:0px">
				<a href="ArrayObject.html">ArrayObject</a>
				 implements <a href="IteratorAggregate.html">IteratorAggregate</a>, <a href="Traversable.html">Traversable</a>, <a href="ArrayAccess.html">ArrayAccess</a>, <a href="Serializable.html">Serializable</a>, <a href="Countable.html">Countable</a>
			</dd>
			<dd style="padding-left:30px">
				<img src="resources/inherit.gif" alt="extended by" />
				<a href="Nette.Collections.Collection.html">Nette\Collections\Collection</a>
				 implements <a href="Nette.Collections.ICollection.html">ICollection</a>
			</dd>
			<dd style="padding-left:60px">
				<img src="resources/inherit.gif" alt="extended by" />
<b>Nette\Collections\Set</b>				 implements <a href="Nette.Collections.ISet.html">ISet</a>
			</dd>
		</dl>



		<div class="classInfo">
			
				<b>Author:</b> David Grudl<br />
			<b>Located at</b> <a href="source-Collections.Set.php.html#18">/Collections/Set.php</a><br />
		</div>
	</div>


	<div id="methodSummary">
		<table class="summary">
		<caption>Method Summary</caption>
		<tr data-order="1 append" id="_append">
			<td align="right" width="1%"><code class="nowrap">
				 public 
				bool
				
				</code>
			</td>

			<td>
			<a class="anchor" href="#_append">#</a>
			<code class="nowrap">
				<a href="source-Collections.Set.php.html#27" title="go to source code"><b>append</b></a>(
					mixed
					<var>$item</var>
			)</code>

			<div class="short">
				
<p>Appends the specified element to the end of this collection.</p>

			</div>

			<div class="detailed">
				
<p>Appends the specified element to the end of this collection.</p>



					<h4>Parameters</h4>
					<div class="smallList">
						<code>$item</code> mixed <br />
					</div>

					<h4>Returns</h4>
					<div class="smallList">bool true if this collection changed as a result of the call</div>

					<h4>Throws</h4>
					<div class="smallList">
						InvalidArgumentException, \NotSupportedException<br />
					</div>

					<h4>Implementation of</h4>
					<div class="smallList"><code><a href="Nette.Collections.ICollection.html#_append">ICollection::append</a></code></div>
			</div>
			</td>
		</tr>
		<tr data-order="1 search" id="_search">
			<td align="right" width="1%"><code class="nowrap">
				 protected 
				int|FALSE
				
				</code>
			</td>

			<td>
			<a class="anchor" href="#_search">#</a>
			<code class="nowrap">
				<a href="source-Collections.Set.php.html#57" title="go to source code"><b>search</b></a>(
					mixed
					<var>$item</var>
			)</code>

			<div class="short">
				
<p>Returns the index of the first occurrence of the specified element,</p>

			</div>

			<div class="detailed">
				
<p>Returns the index of the first occurrence of the specified element,<br>
or FALSE if this collection does not contain this element.</p>



					<h4>Parameters</h4>
					<div class="smallList">
						<code>$item</code> mixed <br />
					</div>

					<h4>Returns</h4>
					<div class="smallList">int|FALSE </div>

					<h4>Throws</h4>
					<div class="smallList">
						<a href="InvalidArgumentException.html">InvalidArgumentException</a> <br />
					</div>

			</div>
			</td>
		</tr>
		<tr data-order="1 offsetSet" id="_offsetSet">
			<td align="right" width="1%"><code class="nowrap">
				 public 
				
				
				</code>
			</td>

			<td>
			<a class="anchor" href="#_offsetSet">#</a>
			<code class="nowrap">
				<a href="source-Collections.Set.php.html#81" title="go to source code"><b>offsetSet</b></a>(
					
					<var>$key</var>, 
					
					<var>$item</var>
			)</code>

			<div class="short">
				
<p>Not supported (only appending).</p>

			</div>

			<div class="detailed">
				
<p>Not supported (only appending).</p>






					<h4>Implementation of</h4>
					<div class="smallList"><code><a href="ArrayAccess.html#_offsetSet">ArrayAccess::offsetSet</a></code></div>
			</div>
			</td>
		</tr>
		<tr data-order="1 offsetGet" id="_offsetGet">
			<td align="right" width="1%"><code class="nowrap">
				 public 
				
				
				</code>
			</td>

			<td>
			<a class="anchor" href="#_offsetGet">#</a>
			<code class="nowrap">
				<a href="source-Collections.Set.php.html#95" title="go to source code"><b>offsetGet</b></a>(
					
					<var>$key</var>
			)</code>

			<div class="short">
				
<p>Not supported.</p>

			</div>

			<div class="detailed">
				
<p>Not supported.</p>






					<h4>Implementation of</h4>
					<div class="smallList"><code><a href="ArrayAccess.html#_offsetGet">ArrayAccess::offsetGet</a></code></div>
			</div>
			</td>
		</tr>
		<tr data-order="1 offsetExists" id="_offsetExists">
			<td align="right" width="1%"><code class="nowrap">
				 public 
				
				
				</code>
			</td>

			<td>
			<a class="anchor" href="#_offsetExists">#</a>
			<code class="nowrap">
				<a href="source-Collections.Set.php.html#105" title="go to source code"><b>offsetExists</b></a>(
					
					<var>$key</var>
			)</code>

			<div class="short">
				
<p>Not supported.</p>

			</div>

			<div class="detailed">
				
<p>Not supported.</p>






					<h4>Implementation of</h4>
					<div class="smallList"><code><a href="ArrayAccess.html#_offsetExists">ArrayAccess::offsetExists</a></code></div>
			</div>
			</td>
		</tr>
		<tr data-order="1 offsetUnset" id="_offsetUnset">
			<td align="right" width="1%"><code class="nowrap">
				 public 
				
				
				</code>
			</td>

			<td>
			<a class="anchor" href="#_offsetUnset">#</a>
			<code class="nowrap">
				<a href="source-Collections.Set.php.html#115" title="go to source code"><b>offsetUnset</b></a>(
					
					<var>$key</var>
			)</code>

			<div class="short">
				
<p>Not supported.</p>

			</div>

			<div class="detailed">
				
<p>Not supported.</p>






					<h4>Implementation of</h4>
					<div class="smallList"><code><a href="ArrayAccess.html#_offsetUnset">ArrayAccess::offsetUnset</a></code></div>
			</div>
			</td>
		</tr>

		</table>
	</div>


	<h2>Methods Inherited From <a href="Nette.Collections.Collection.html#methodSummary">Collection</a></h2>
	<div class="box"><code>
		<a href="Nette.Collections.Collection.html#___construct">__construct()</a>, <a href="Nette.Collections.Collection.html#_append">append()</a>, <a href="Nette.Collections.Collection.html#_remove">remove()</a>, <a href="Nette.Collections.Collection.html#_search">search()</a>, <a href="Nette.Collections.Collection.html#_clear">clear()</a>, <a href="Nette.Collections.Collection.html#_contains">contains()</a>, <a href="Nette.Collections.Collection.html#_import">import()</a>, <a href="Nette.Collections.Collection.html#_getItemType">getItemType()</a>, <a href="Nette.Collections.Collection.html#_setReadOnly" class="deprecated">setReadOnly()</a>, <a href="Nette.Collections.Collection.html#_isReadOnly" class="deprecated">isReadOnly()</a>, <a href="Nette.Collections.Collection.html#_beforeAdd">beforeAdd()</a>, <a href="Nette.Collections.Collection.html#_getIterator">getIterator()</a>, <a href="Nette.Collections.Collection.html#_exchangeArray">exchangeArray()</a>, <a href="Nette.Collections.Collection.html#_setArray">setArray()</a>, <a href="Nette.Collections.Collection.html#_getReflection">getReflection()</a>, <a href="Nette.Collections.Collection.html#___call">__call()</a>, <a href="Nette.Collections.Collection.html#___callStatic">__callStatic()</a>, <a href="Nette.Collections.Collection.html#___get">__get()</a>, <a href="Nette.Collections.Collection.html#___set">__set()</a>, <a href="Nette.Collections.Collection.html#___isset">__isset()</a>, <a href="Nette.Collections.Collection.html#___unset">__unset()</a>, <a href="Nette.Collections.Collection.html#_freeze">freeze()</a>, <a href="Nette.Collections.Collection.html#_isFrozen">isFrozen()</a>, <a href="Nette.Collections.Collection.html#___clone">__clone()</a>, <a href="Nette.Collections.Collection.html#_updating">updating()</a>
	</code></div>
	<h2>Methods Inherited From <a href="ArrayObject.html#methodSummary">ArrayObject</a></h2>
	<div class="box"><code>
		<a href="ArrayObject.html#___construct">__construct()</a>, <a href="ArrayObject.html#_offsetExists">offsetExists()</a>, <a href="ArrayObject.html#_offsetGet">offsetGet()</a>, <a href="ArrayObject.html#_offsetSet">offsetSet()</a>, <a href="ArrayObject.html#_offsetUnset">offsetUnset()</a>, <a href="ArrayObject.html#_append">append()</a>, <a href="ArrayObject.html#_getArrayCopy">getArrayCopy()</a>, <a href="ArrayObject.html#_count">count()</a>, <a href="ArrayObject.html#_getFlags">getFlags()</a>, <a href="ArrayObject.html#_setFlags">setFlags()</a>, <a href="ArrayObject.html#_asort">asort()</a>, <a href="ArrayObject.html#_ksort">ksort()</a>, <a href="ArrayObject.html#_uasort">uasort()</a>, <a href="ArrayObject.html#_uksort">uksort()</a>, <a href="ArrayObject.html#_natsort">natsort()</a>, <a href="ArrayObject.html#_natcasesort">natcasesort()</a>, <a href="ArrayObject.html#_unserialize">unserialize()</a>, <a href="ArrayObject.html#_serialize">serialize()</a>, <a href="ArrayObject.html#_getIterator">getIterator()</a>, <a href="ArrayObject.html#_exchangeArray">exchangeArray()</a>, <a href="ArrayObject.html#_setIteratorClass">setIteratorClass()</a>, <a href="ArrayObject.html#_getIteratorClass">getIteratorClass()</a>
	</code></div>



	<h2>Constants Inherited From <a href="ArrayObject.html#constantSummary">ArrayObject</a></h2>
	<div class="box"><code>STD_PROP_LIST, ARRAY_AS_PROPS</code></div>




</div>

	<div id="footer">
		Nette Framework API documentation generated by <a href="http://apigen.org">ApiGen</a>
	</div>
</div>
</body>
</html>
